<!-- 示例模板 -->
<template>
    <div class="e-tree-table">
        <el-table
            :data="tableData"
            style="width: 100%; margin-bottom: 20px"
            row-key="id"
            border
            default-expand-all
            :tree-props="{
                children: 'children',
                hasChildren: 'hasChildren'
            }"
        >
            <el-table-column prop="a" label="项目编号"> </el-table-column>
            <el-table-column prop="b" label="项目名称"> </el-table-column>
            <el-table-column prop="c" label="分部名称"> </el-table-column>
            <el-table-column prop="d" label="标准数量">
                <template slot-scope="scope">
                    <el-input
                        v-model="scope.row.d"
                        placeholder="请输入内容"
                        size="mini"
                    ></el-input>
                </template>
            </el-table-column>
            <el-table-column prop="e" label="标准单价">
                <template slot-scope="scope">
                    <el-input
                        v-model="scope.row.e"
                        placeholder="请输入内容"
                        size="mini"
                    ></el-input>
                </template>
            </el-table-column>
        </el-table>
    </div>
</template>

<script>
export default {
    data () {
        return {
            tableData: [
                {
                    id: '1',
                    a: 'a',
                    b: 'b',
                    c: 'c',
                    d: '',
                    e: '',
                    children: [
                        {
                            id: '1-1',
                            a: 'a',
                            b: 'b',
                            c: 'c',
                            d: '',
                            e: '',
                            children: [
                                {
                                    id: '1-1-1',
                                    a: 'a',
                                    b: 'b',
                                    c: 'c',
                                    d: '',
                                    e: ''
                                }
                            ]
                        }
                    ]
                }
            ]
        }
    }
}
</script>

<style lang="scss" scoped></style>
